package com.gitee.wsl.security.hash


import com.gitee.wsl.ext.array.toByteString
import com.gitee.wsl.ext.string.encryptMD5
import com.gitee.wsl.ext.string.encryptSHA256
import com.gitee.wsl.io.hex
import com.gitee.wsl.struct.generator.Generator
import kotlin.test.Test


class Md5Tests {

    @OptIn(ExperimentalStdlibApi::class)
    @Test
    fun testMd5(){
        val a = Generator.FileName.invoke(10)
        println("MD5    a:$a ->"+a.md5())
        println("MD5    a:$a ->"+a.md5())
        println("       a:$a ->"+a.encryptMD5())
        //println("sha512 a:"+"a".sha512().toHexString())
        //println("       a:"+"a".encryptSHA512())
    }
}